package com.ruoyi.system.service.impl;

import java.util.List;

import com.ruoyi.db.domain.system.MpClientReturnRecord;
import com.ruoyi.db.mapper.system.MpClientReturnRecordMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.service.IMpClientReturnRecordService;

import javax.transaction.Transactional;

/**
 * 用户参与定返活动记录Service业务层处理
 * 
 * @author ruoyi
 * @date 2022-08-05
 */
@Service
@Transactional(rollbackOn = Exception.class)
public class MpClientReturnRecordServiceImpl implements IMpClientReturnRecordService 
{
    @Autowired
    private MpClientReturnRecordMapper mpClientReturnRecordMapper;

    /**
     * 查询用户参与定返活动记录
     * 
     * @param id 用户参与定返活动记录主键
     * @return 用户参与定返活动记录
     */
    @Override
    public MpClientReturnRecord selectMpClientReturnRecordById(Long id)
    {
        return mpClientReturnRecordMapper.selectMpClientReturnRecordById(id);
    }

    /**
     * 查询用户参与定返活动记录列表
     * 
     * @param mpClientReturnRecord 用户参与定返活动记录
     * @return 用户参与定返活动记录
     */
    @Override
    public List<MpClientReturnRecord> selectMpClientReturnRecordList(MpClientReturnRecord mpClientReturnRecord)
    {
        return mpClientReturnRecordMapper.selectListByTime(mpClientReturnRecord);
    }

    /**
     * 新增用户参与定返活动记录
     * 
     * @param mpClientReturnRecord 用户参与定返活动记录
     * @return 结果
     */
    @Override
    public int insertMpClientReturnRecord(MpClientReturnRecord mpClientReturnRecord)
    {
        return mpClientReturnRecordMapper.insertMpClientReturnRecord(mpClientReturnRecord);
    }

    /**
     * 修改用户参与定返活动记录
     * 
     * @param mpClientReturnRecord 用户参与定返活动记录
     * @return 结果
     */
    @Override
    public int updateMpClientReturnRecord(MpClientReturnRecord mpClientReturnRecord)
    {
        return mpClientReturnRecordMapper.updateMpClientReturnRecord(mpClientReturnRecord);
    }

    /**
     * 批量删除用户参与定返活动记录
     * 
     * @param ids 需要删除的用户参与定返活动记录主键
     * @return 结果
     */
    @Override
    public int deleteMpClientReturnRecordByIds(Long[] ids)
    {
        return mpClientReturnRecordMapper.deleteMpClientReturnRecordByIds(ids);
    }

    /**
     * 删除用户参与定返活动记录信息
     * 
     * @param id 用户参与定返活动记录主键
     * @return 结果
     */
    @Override
    public int deleteMpClientReturnRecordById(Long id)
    {
        return mpClientReturnRecordMapper.deleteMpClientReturnRecordById(id);
    }
}
